package com.bw.module_home.home.repo

import com.bw.module_home.home.api.HomeApiServer
import com.bw.module_home.home.model.HomeNetModule
import kotlinx.coroutines.Dispatchers
import kotlinx.coroutines.flow.flow
import kotlinx.coroutines.flow.flowOn
import javax.inject.Inject

class HomeRepo @Inject constructor() {
    @Inject
    @HomeNetModule.CommonHomeApi

    lateinit var api: HomeApiServer


    fun getNotice(page:Int,size:Int)= flow {
        emit(api.getHomeList(page,size))
    }.flowOn(Dispatchers.IO)

}